package com.xxx.service.seviceImpl;

import com.xxx.eneity.Contest;
import com.xxx.eneity.ContestNotice;
import com.xxx.eneity.ContestSpecies;
import com.xxx.mapper.ContestMapper;
import com.xxx.service.ContestService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class ContestServiceImpl implements ContestService {
    @Autowired
    private ContestMapper contestMapper;
    @Override
    public int addContestSpecies(String speciesName) {
        return contestMapper.addContestSpecies(speciesName);
    }

    @Override
    public List<ContestSpecies> getContestSpeciesList() {
        return contestMapper.getContestSpeciesList();
    }

    @Override
    public int removeContestSpecies(Integer speciesId) {
        return contestMapper.removeContestSpecies(speciesId);
    }

    @Override
    public int addContest(Contest contest) {
        return contestMapper.addContest(contest);
    }

    @Override
    public int editContest(Contest contest) {
        return contestMapper.editContest(contest);
    }

    @Override
    public int removeContest(Integer contestId) {
        return contestMapper.removeContest(contestId);
    }

    @Override
    public int editContestSpecies(Integer contestSpeciesId, String contestSpeciesName) {
        return contestMapper.editContestSpecies(contestSpeciesId,contestSpeciesName);
    }

    @Override
    public List<Contest> getContestList(Integer contestSpeciesId, Integer status) {
        return contestMapper.getContestList(contestSpeciesId, status);
    }

    @Override
    public int deleteContestNotice(Integer contestNoticeId) {
        return contestMapper.deleteContestNotice(contestNoticeId);
    }

    @Override
    public int editContestNotice(ContestNotice contestNotice) {
        return contestMapper.editContestNotice(contestNotice);
    }

    @Override
    public List<ContestNotice> getContestNoticeList(Integer contestId) {
        return contestMapper.getContestNoticeList(contestId);
    }

    @Override
    public int addContestNotice(ContestNotice contestNotice) {
        return contestMapper.addContestNotice(contestNotice);
    }
}
